package com.pengtu.entity.trial;

import java.util.Set;

import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.JoinColumn;
import javax.persistence.JoinTable;
import javax.persistence.ManyToMany;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

import org.hibernate.annotations.Fetch;
import org.hibernate.annotations.FetchMode;

import com.pengtu.entity.IdEntity;
import com.pengtu.entity.receive.Entrust;
import com.pengtu.entity.receive.Trialwt01;
import com.pengtu.entity.receive.Trialwt02;
import com.pengtu.entity.receive.Trialwt03;
import com.pengtu.entity.receive.Trialwt04;
import com.pengtu.entity.receive.Trialwt05;
import com.pengtu.entity.receive.Trialwt06;
import com.pengtu.entity.receive.Trialwt07;
import com.pengtu.entity.receive.Trialwt08;
import com.pengtu.entity.receive.Trialwt09;

/**
 * TCTrialOrder generated by hbm2java
 */
@Entity
@Table(name = "T_C_TRIAL_ORDER")
public class Order extends IdEntity {

	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;
	private String reportcode;
	private String type;
	private String name;
	private String trialtype;
	private String standard;
	private Entrust entrust;
	private Set<Trialwt01> trialwt01s;
	private Set<Trialwt02> trialwt02s;
	private Set<Trialwt03> trialwt03s;
	private Set<Trialwt04> trialwt04s;
	private Set<Trialwt05> trialwt05s;
	private Set<Trialwt06> trialwt06s;
	private Set<Trialwt07> trialwt07s;
	private Set<Trialwt08> trialwt08s;
	private Set<Trialwt09> trialwt09s;
	private String status;

	public Order() {
	}

	public void setTrialwt01s(Set<Trialwt01> trialwt01s) {
		this.trialwt01s = trialwt01s;
	}

	@ManyToMany(cascade = { CascadeType.PERSIST, CascadeType.MERGE }, fetch = FetchType.EAGER)
	@JoinTable(name = "R_C_TRIAL_ORDERRELATION01", joinColumns = { @JoinColumn(name = "ORDERID") }, inverseJoinColumns = { @JoinColumn(name = "SAMPLEID") })
	// Fecth策略定义
	@Fetch(FetchMode.SUBSELECT)
	public Set<Trialwt01> getTrialwt01s() {
		return trialwt01s;
	}

	public void setTrialwt02s(Set<Trialwt02> trialwt02s) {
		this.trialwt02s = trialwt02s;
	}

	@ManyToMany(cascade = { CascadeType.PERSIST, CascadeType.MERGE }, fetch = FetchType.EAGER)
	@JoinTable(name = "R_C_TRIAL_ORDERRELATION02", joinColumns = { @JoinColumn(name = "ORDERID") }, inverseJoinColumns = { @JoinColumn(name = "SAMPLEID") })
	// Fecth策略定义
	@Fetch(FetchMode.SUBSELECT)
	public Set<Trialwt02> getTrialwt02s() {
		return trialwt02s;
	}

	public void setTrialwt03s(Set<Trialwt03> trialwt03s) {
		this.trialwt03s = trialwt03s;
	}

	@ManyToMany(cascade = { CascadeType.PERSIST, CascadeType.MERGE }, fetch = FetchType.EAGER)
	@JoinTable(name = "R_C_TRIAL_ORDERRELATION03", joinColumns = { @JoinColumn(name = "ORDERID") }, inverseJoinColumns = { @JoinColumn(name = "SAMPLEID") })
	// Fecth策略定义
	@Fetch(FetchMode.SUBSELECT)
	public Set<Trialwt03> getTrialwt03s() {
		return trialwt03s;
	}

	public void setTrialwt04s(Set<Trialwt04> trialwt04s) {
		this.trialwt04s = trialwt04s;
	}

	@ManyToMany(cascade = { CascadeType.PERSIST, CascadeType.MERGE }, fetch = FetchType.EAGER)
	@JoinTable(name = "R_C_TRIAL_ORDERRELATION04", joinColumns = { @JoinColumn(name = "ORDERID") }, inverseJoinColumns = { @JoinColumn(name = "SAMPLEID") })
	// Fecth策略定义
	@Fetch(FetchMode.SUBSELECT)
	public Set<Trialwt04> getTrialwt04s() {
		return trialwt04s;
	}

	public void setTrialwt05s(Set<Trialwt05> trialwt05s) {
		this.trialwt05s = trialwt05s;
	}

	@ManyToMany(cascade = { CascadeType.PERSIST, CascadeType.MERGE }, fetch = FetchType.EAGER)
	@JoinTable(name = "R_C_TRIAL_ORDERRELATION05", joinColumns = { @JoinColumn(name = "ORDERID") }, inverseJoinColumns = { @JoinColumn(name = "SAMPLEID") })
	// Fecth策略定义
	@Fetch(FetchMode.SUBSELECT)
	public Set<Trialwt05> getTrialwt05s() {
		return trialwt05s;
	}

	public void setTrialwt06s(Set<Trialwt06> trialwt06s) {
		this.trialwt06s = trialwt06s;
	}

	@ManyToMany(cascade = { CascadeType.PERSIST, CascadeType.MERGE }, fetch = FetchType.EAGER)
	@JoinTable(name = "R_C_TRIAL_ORDERRELATION06", joinColumns = { @JoinColumn(name = "ORDERID") }, inverseJoinColumns = { @JoinColumn(name = "SAMPLEID") })
	// Fecth策略定义
	@Fetch(FetchMode.SUBSELECT)
	public Set<Trialwt06> getTrialwt06s() {
		return trialwt06s;
	}

	/**
	 * trialwt07s
	 * 
	 * @return the trialwt07s
	 * @since 1.0.0
	 */
	@ManyToMany(cascade = { CascadeType.PERSIST, CascadeType.MERGE }, fetch = FetchType.EAGER)
	@JoinTable(name = "R_C_TRIAL_ORDERRELATION07", joinColumns = { @JoinColumn(name = "ORDERID") }, inverseJoinColumns = { @JoinColumn(name = "SAMPLEID") })
	// Fecth策略定义
	@Fetch(FetchMode.SUBSELECT)
	public Set<Trialwt07> getTrialwt07s() {
		return trialwt07s;
	}

	public void setTrialwt08s(Set<Trialwt08> trialwt08s) {
		this.trialwt08s = trialwt08s;
	}

	@ManyToMany(cascade = { CascadeType.PERSIST, CascadeType.MERGE }, fetch = FetchType.EAGER)
	@JoinTable(name = "R_C_TRIAL_ORDERRELATION08", joinColumns = { @JoinColumn(name = "ORDERID") }, inverseJoinColumns = { @JoinColumn(name = "SAMPLEID") })
	// Fecth策略定义
	@Fetch(FetchMode.SUBSELECT)
	public Set<Trialwt08> getTrialwt08s() {
		return trialwt08s;
	}

	public void setTrialwt09s(Set<Trialwt09> trialwt09s) {
		this.trialwt09s = trialwt09s;
	}

	@ManyToMany(cascade = { CascadeType.PERSIST, CascadeType.MERGE }, fetch = FetchType.EAGER)
	@JoinTable(name = "R_C_TRIAL_ORDERRELATION09", joinColumns = { @JoinColumn(name = "ORDERID") }, inverseJoinColumns = { @JoinColumn(name = "SAMPLEID") })
	// Fecth策略定义
	@Fetch(FetchMode.SUBSELECT)
	public Set<Trialwt09> getTrialwt09s() {
		return trialwt09s;
	}

	/**
	 * @param trialwt07s
	 *            the trialwt07s to set
	 */
	public void setTrialwt07s(Set<Trialwt07> trialwt07s) {
		this.trialwt07s = trialwt07s;
	}

	@ManyToOne
	@JoinColumn(name = "ENTRUSTID")
	public Entrust getEntrust() {
		return entrust;
	}

	public void setEntrust(Entrust entrust) {
		this.entrust = entrust;
	}

	public String getType() {
		return this.type;
	}

	public void setType(String type) {
		this.type = type;
	}

	/**
	 * standard
	 * 
	 * @return the standard
	 * @since 1.0.0
	 */

	public String getStandard() {
		return standard;
	}

	/**
	 * @param standard
	 *            the standard to set
	 */
	public void setStandard(String standard) {
		this.standard = standard;
	}

	/**
	 * reportcode
	 * 
	 * @return the reportcode
	 * @since 1.0.0
	 */

	public String getReportcode() {
		return reportcode;
	}

	/**
	 * @param reportcode
	 *            the reportcode to set
	 */
	public void setReportcode(String reportcode) {
		this.reportcode = reportcode;
	}

	/**
	 * name
	 * 
	 * @return the name
	 * @since 1.0.0
	 */

	public String getName() {
		return name;
	}

	/**
	 * @param name
	 *            the name to set
	 */
	public void setName(String name) {
		this.name = name;
	}

	/**
	 * trialtype
	 * 
	 * @return the trialtype
	 * @since 1.0.0
	 */

	public String getTrialtype() {
		return trialtype;
	}

	/**
	 * @param trialtype
	 *            the trialtype to set
	 */
	public void setTrialtype(String trialtype) {
		this.trialtype = trialtype;
	}

	/**
	 * status
	 * 
	 * @return the status
	 * @since 1.0.0
	 */
	@Column(name = "STATUS")
	public String getStatus() {
		return status;
	}

	/**
	 * @param status
	 *            the status to set
	 */
	public void setStatus(String status) {
		this.status = status;
	}

}
